package cn.ven.entity;

import java.util.Date;

public class Book {
    private Integer id;//书本id
    private String sn; //序号
    private String name; //书名
    private double price; //价格
    private String author; //作者
    private String publisher; //出版商
    private Integer typeid; //类型id ---跟类型表绑定，t_book外键
    private Date tpublish; //出版时间
    private String picture; //图片id
    private Integer rate; //点赞数
    private Integer favnum; //喜欢数
    private Integer salenum; //销售量
    private BookType booktype; //书本类型对象

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getSn() {
        return sn;
    }

    public void setSn(String sn) {
        this.sn = sn;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public String getPublisher() {
        return publisher;
    }

    public void setPublisher(String publisher) {
        this.publisher = publisher;
    }

    public Integer getTypeid() {
        return typeid;
    }

    public void setTypeid(Integer typeid) {
        this.typeid = typeid;
    }

    public Date getTpublish() {
        return tpublish;
    }

    public void setTpublish(Date tpublish) {
        this.tpublish = tpublish;
    }

    public String getPicture() {
        return picture;
    }

    public void setPicture(String picture) {
        this.picture = picture;
    }

    public Integer getRate() {
        return rate;
    }

    public void setRate(Integer rate) {
        this.rate = rate;
    }

    public Integer getFavnum() {
        return favnum;
    }

    public void setFavnum(Integer favnum) {
        this.favnum = favnum;
    }

    public Integer getSalenum() {
        return salenum;
    }

    public void setSalenum(Integer salenum) {
        this.salenum = salenum;
    }

    public BookType getBooktype() {
        return booktype;
    }

    public void setBooktype(BookType booktype) {
        this.booktype = booktype;
    }

    @Override
    public String toString() {
        return "Book{" +
                "id=" + id +
                ", sn='" + sn + '\'' +
                ", name='" + name + '\'' +
                ", price=" + price +
                ", author='" + author + '\'' +
                ", publisher='" + publisher + '\'' +
                ", typeid=" + typeid +
                ", tublish=" + tpublish +
                ", picture='" + picture + '\'' +
                ", rate=" + rate +
                ", favnum=" + favnum +
                ", salenum=" + salenum +
                ", booktype=" + booktype +
                '}';
    }
}
